Skip to content

feat(nomad): per-server config + one-click bootstrap + installer - #1

Merged
pipozzz merged 1 commit into
mainfrom
feat/nomad-per-server-and-bootstrap
Sep 1, 2026
Merged

pipozzz merged 1 commit into
mainfrom
feat/nomad-per-server-and-bootstrap

Conversation

@pipozzz

@pipozzz pipozzz commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds the two remaining functional pieces for nomploy's Nomad orchestration plus a fresh-server installer.

Per-server Nomad config

  • Dashboard router resolves each server's nomadAddress/nomadToken/nomadNamespace from the DB (127.0.0.1 fallback for the control-plane-local cluster), with an org-ownership auth check.
  • Every procedure takes an optional serverId; namespaced endpoints scope by namespace.
  • Transport isolated in nomadClient() so an SSH-tunnel path can drop in later.
  • Dashboard gains a cluster selector threading serverId into all components.

One-click Nomad bootstrap

  • getNomadBootstrapCommand() generates an SSH install script (Docker + Consul + Nomad + CNI as systemd, single-node server+client, docker plugin with private-registry auth).
  • nomad.bootstrapServer streams the install over SSH and auto-saves the server's Nomad address on success.
  • 'Bootstrap Nomad' button + live log viewer in per-server Nomad settings, surfaced via the server dropdown.

Installer

  • install.sh: one-line control-plane installer for a fresh Linux server.

Both packages typecheck clean and the server bundle builds.

🤖 Generated with Claude Code

- Nomad dashboard router resolves per-server address/token/namespace from the
  server's DB columns (127.0.0.1 fallback for the local cluster), with an
  org-ownership auth check; transport isolated in nomadClient() so an SSH tunnel
  can drop in later. Dashboard gains a cluster selector.
- nomad.bootstrapServer streams a Docker+Consul+Nomad+CNI install over SSH and
  auto-saves the server's Nomad address on success. Surfaced as a 'Bootstrap
  Nomad' button in per-server Nomad settings (wired into the server dropdown).
- install.sh: one-line control-plane installer for a fresh server.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@pipozzz
pipozzz merged commit 4face40 into main Sep 1, 2026
@pipozzz
pipozzz deleted the feat/nomad-per-server-and-bootstrap branch September 1, 2026 10:08
pipozzz added a commit that referenced this pull request Sep 4, 2026
… health)

- Join now runs a pre-flight SSH+sudo check before allocating an IP or
  installing anything. The #1 join failure is a node that doesn't trust the
  panel's SSH key yet; on an auth failure we print the exact public key plus a
  one-line authorized_keys command so it's a copy-paste fix instead of a
  cryptic late error. Non-auth failures fall through to the firewall hint.
- Members table gains a per-row Remove action (with the same quorum-safe
  confirm + force-below-3 guard), so any node can be removed from one place
  without opening its own settings. Leave-cluster now drives the same shared
  dialog.
- getClusterMembers returns a `leader` flag; the table shows a leader badge and
  a "N servers · fault tolerance N" summary so cluster health is obvious.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
pipozzz added a commit that referenced this pull request Sep 29, 2026
…d; add release preflight

#1 Pack deploys re-cloned the whole registry every time via `nomad-pack
registry add`. Now that deploys are pinned to an immutable ref, skip the add
when that ref's pack cache dir already exists
($HOME/.cache/nomad/packs/<registry>/<ref>) — much faster deploys for a
large registry, safe because the ref can't change. Unpinned (fallback) still
re-adds to pull latest.

#3 scripts/check.sh runs the CI-equivalent prod build (switch:prod + cold
tsc -p tsconfig.server.json) — the only reliable way to catch CI-only type
failures (bit us on v0.30.133/.135; dev `tsc --noEmit` + its .tsbuildinfo
cache hide them). release.sh now runs it as a pre-flight gate (SKIP_CHECK=1
to override). App tsc is informational only — Next has ignoreBuildErrors.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant